package com.example.mydesignmodule.zhuangshi;

/**
 * @author tgw
 * @date 2021/3/11
 * @describe
 */
class ConcreteComponentA extends Decorator {
    public ConcreteComponentA(Component component) {
        super(component);
        component.people = new People();
    }

    @Override
    void operate() {

        super.operate();
        component.people.setDress("小西装");
        component.people.setHat("毡帽");
        operateA();

    }

    void operateA() {
        System.out.println("装饰A后的模样"+component.people.toString());

    }

    void operateB() {
        System.out.println("本来的模样");

    }
}
